﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="UCSuKien.ascx.cs" Inherits="UControls_UCSuKien" %>
<div class="KhoiXanhLa">Sự kiện tiêu điểm</div>
<asp:DataList ID="DataList1" runat="server" DataKeyField="BaiVietID" 
    DataSourceID="EntityDataSource1" Width="100%">
    <ItemTemplate>
        <asp:HyperLink ID="HyperLink1" runat="server" Text='<%# Eval("TuaBaiViet") %>'  
        NavigateUrl='<%# "~/Pages/BaiViet.aspx?IDBaiViet="+Eval("BaiVietID") %>' CssClass="LinkSuKien"></asp:HyperLink><br />
        <asp:Image ID="Image1" runat="server" 
                ImageUrl='<%# "~/Photos/BaiViet/"+Eval("HinhDaiDien") %>' Width="175px" />
    </ItemTemplate>
</asp:DataList>
<asp:EntityDataSource ID="EntityDataSource1" runat="server" 
    ConnectionString="name=EDiamondEntities1" 
    DefaultContainerName="EDiamondEntities1" EnableFlattening="False" 
    EntitySetName="BaiViets" OrderBy="it.NgayCapNhat DESC,it.BaiVietID DESC skip 0 limit 3" 
    
    Select="it.[BaiVietID], it.[TuaBaiViet], it.[HinhDaiDien], it.[NgayCapNhat], it.[TheLoai]" 
    Where="it.TheLoai=4">
</asp:EntityDataSource>
